#include <iomanip>
#include <iostream>
#include <codecvt>
#include <thread>
#include <chrono>//时间库
#include <shared_mutex>
#include <mutex>
#include <random>
#include <cstring>

using namespace std;

//数据帧头
const uint8_t FRAME_HEADER1 = 0xEB;
const uint8_t FRAME_HEADER2 = 0x90;

//飞机状态枚举
enum class DroneStatus : uint8_t{
  IDLE  = 0x55,//空闲
  BUSY  = 0xAA,//忙碌
  FAULT = 0xFF,//故障
};//指定了其底层数据类型为uint8_t

//航点数据结构
struct Waypoint{
  uint32_t id;
  double longitude;
  double latitude;
  double altitude;
};

vector<uint8_t> generateTaskData();
//航点数据生成
vector<uint8_t> generateWaypointData();
//侦察目标数据生成
vector<uint8_t> generateTargetData();
void printWaypointData(uint8_t droneID, int32_t numPoints, const vector<Waypoint>& waypoints);
void printTargetData(double radiation, double longtitude, double latitude);

//----------------------------//
void printTaskData(uint32_t droneID, uint32_t targetID, double longitude, double latitude);
//----------------------------//
